import styled from 'styled-components';
import logoPic from './../../static/logo.png';

export const HeaderWrapper = styled.div`
  height: 56px;
  border-bottom: 1px solid #eee;
`

export const Logo = styled.a.attrs(
  {
    href: '/'
  }
)`
  display: inline-block;
  float: left;
  width: 100px;
  height: 56px;
  background: url(${logoPic});
  background-size: contain;
`

export const NavContainer = styled.div`
  box-sizing: border-box;
  width: 960px;
  height: 56px;
  margin: 0 auto;
  padding-right: 40px;
`;

export const NavItem = styled.div`
  padding: 0 15px;
  line-height: 56px;
  color: #333;
  cursor: pointer;
  
  &.active {
    color: #ea6f5a;
  }
  
  &.left {
    float: left;
  }
  &.left:hover {
    background: #f5f5f5;
  }
  
  &.right {
    float: right;
    color: #969696;
  }
`;

export const NavSearch = styled.input.attrs({
  placeholder: "搜索"
})`
  box-sizing: border-box;
  width: 160px;
  height: 38px;
  margin-top: 9px;
  margin-left: 30px;
  padding: 0 40px 0 20px;
  background: #eee;
  font-size: 14px;
  color: #777;
  border: none;
  outline: none;
  border-radius: 19px;
  
  &::placeholder {
    color: #999;
  }
`;

export const Additional = styled.div`
  position: absolute;
  top: 0;
  right: 0;
`;

export const Button = styled.button`
  float: right;
  box-sizing: border-box;
  margin-top: 9px;
  margin-right: 10px;
  padding: 0 15px;
  height: 38px;
  font-size: 15px;
  line-height: 38px;
  border: 1px solid #ec6149;
  border-radius: 19px;
  outline: none;
  cursor: pointer;
  background: #fff;
  
  &.register {
    width: 80px;
    margin-right: 15px;
    color: #ec6149;
  }
  
  &.writting {
    width: 100px;
    color: #fff;
    background-color: #ec6149;
  }
`;
